package com.example.util;

import lombok.extern.slf4j.Slf4j;

import java.text.SimpleDateFormat;
import java.util.Date;

@Slf4j
public final class DateUtil {

    public final static String DATE_FORMAT = "yyyy-MM-dd HH:mm:ss";

    public final static SimpleDateFormat SIMPLE_DATE_FORMAT = new SimpleDateFormat(DATE_FORMAT);

    public static String date2Str(Date date) {
        return SIMPLE_DATE_FORMAT.format(date);
    }

    private DateUtil() {
    }

}
